package com.laolei.zookeeper.core.impl;

import com.laolei.zookeeper.core.SerializationOperations;

public class StringSerializationOperations implements SerializationOperations<String>{

	@Override
	public byte[] serialize(String data) {
		if(data==null)
			return null;
		return data.getBytes();
	}

	@Override
	public String deserialize(byte[] data) {
		if(data==null)
			return null;
		return new String(data);
	}
 
}
